<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Content Plugins</title>
<link rel="stylesheet" href="../css/prettify.css" />
<style type="text/css">
body{font-size:0.75em;font-family:Tahoma, Geneva, sans-serif;}
dt{color:red;font-size:14px;}
</style>
<script type="text/javascript" src="../js/prettify.js"></script>
</head>
<body onload="prettyPrint();">
<h1>内容插件（Content Plugins）</h1>
<hr />
<h2>{CBImageScale}</h2>
<h3>{CBImageScale}使用</h3>
<pre class="prettyprint linenums">
{CBImageScale field:myimage; width:50; }
</pre>
<h3>可选的参数</h3>
<dl>
	<dt>width: 50; </dt>
	<dd> will render the image with the width of 50 pixels. If only the width is given, it will use the same value for height. Either width or height is required.</dd>
	<dt>height: 50; </dt>
	<dd> will render the image with the height of 50 pixels. If only the height is given, it will use the same value for height. Either width or height is required.</dd>
	<dt>field: *fieldname*; </dt>
	<dd> the name of the field to pick the path to the image from (usually a file upload field).</dd>
	<dt>background-color: #ffffff; </dt>
	<dd> the color for the background space if the scaled image doesn't fit within the given width/height boundaries as hex value.</dd>
	<dt>folder: tmp; </dt>
	<dd> an alternative cache folder. Default is <span style="color:red;">media/contentbuilder/plugins/image_scale/cache</span></dd>
	<dt>cache: 86400; </dt>
	<dd> the caching time for this image. Default is 86400 seconds. If set to „none“, caching will be disabled for this image.</dd>
	<dt>global_cache: 86400; </dt>
	<dd> the global cache time for all images within the given folder. All cached images within this folder will be deleted after the given seconds. Default is 86400 seconds.</dd>
	<dt>align: left; </dt>
	<dd> Will float the image into the given direction. Possible values are „left“ or „right“.</dd>
	<dt>open: true; </dt>
	<dd> if set to „true“, the scaled image will be clickable, opening the original image within a modal window. If the dimensions of the image exceed a certain size, it will skip displaying as modal and instead use a regular javascript based popup window.</dd>
	<dt>alt: *some alternative text*;</dt>
	<dd> adds an alternative alt text to the generated image tag</dd>
	<dt>title: *some title text*;</dt>
	<dd> adds a title to the generated image tag</dd>
</dl>

<hr />

<h2>{CBDownload}</h2>
<h3>{CBDownload}使用</h3>
<pre class="prettyprint linenums">
{CBDownload field:myfile;}
</pre>
<h3>可选的参数</h3>
<dl>
	<dt>field: *fieldname*; </dt>
	<dd> the name of the upload field</dd>
	<dt>box-style: border-width:thin::border-color:#000000;</dt>
	<dd> the style of the box that contains the download. Use regular CSS here. Please seperate each css directive by „::“ instead of semicolon!</dd>
	<dt>info-style: color: red; </dt>
	<dd> same usage as box-style, will be applied to the container that is wrapped by the box.</dd>
	<dt>align: left; </dt>
	<dd> Will float the image into the given direction. Possible values are „left“ or „right“.</dd>
	<dt>info: false; </dt>
	<dd> if set to „false“ all info for this download will be turned off. Default is „true“.</dd>
	<dt>hide-filename: true; </dt>
	<dd> if set to „true“, the filename will be hidden from the info.</dd>
	<dt>hide-mime: true; </dt>
	<dd> if set to „true“, the mime type will be hidden from the info.</dd>
	<dt>hide-size: true; </dt>
	<dd> if set to „true“, the size will be hidden from the info.</dd>
	<dt>hide-downloads: true; </dt>
	<dd> if set to „true“, the amount of downloads will be hidden from the info.</dd>
</dl>
<hr />
<h2>{CBVerify}</h2>
<h3>{CBVerify}使用</h3>
<pre class="prettyprint linenums">
{CBVerify 
plugin: paypal; 
require-view: 30; 
verify-view: 36; 
verify-levels: view, new, edit; 
verification-name: 10 Day Subscription; 
desc: Click here to pay!;
amount: 19.00;
}
</pre>
<h3>可选的参数</h3>
<dl>
	<dt>plugin: paypal; </dt>
	<dd> choosing the verification plugin to use.</dd>
	<dt>verification-name: Subscription; </dt>
	<dd> a descriptive name for the verification. Verification plugins such as paypal might use it as item name if none given.</dd>
	<dt>verification-msg: Successfully verified! </dt>
	<dd> a custom verification message.</dd>
	<dt>image: media/images/paypal.gif </dt>
	<dd> using an image url instead of a link.</dd>
	<dt>image-width: 50; </dt>
	<dd> the width of the image.</dd>
	<dt>image-height: 50; </dt>
	<dd> the height of the image.</dd>
	<dt>desc: Click here to pay! </dt>
	<dd> a text to display within the link or, if an image is used, having the description as image title.</dd>
	<dt>verify-view: 18; </dt>
	<dd> the ID of the view you want to verify for the current user.</dd>
	<dt>verify-levels: new, view, edit </dt>
	<dd> granting the levels „new“, „view“ and „edit“ after a successfull verification. </dd>
	<dt>require-view: 30; </dt>
	<dd> force the use to fill in a form from another view (or this view) with the given ID.</dd>
	<dt>return-admin: index.php </dt>
	<dd> an alternative return url after verification if the verification happened in backend context. Default is returning to the corresponding list of the verified view.</dd>
	<dt>return-site: index.php </dt>
	<dd> an alternative return url after verification if the verification happened in frontend context. Default is returning to the corresponding list of the verified view.</dd>
</dl>
<h3>PayPal:</h3>
<dl>
	<dt>amount: 19.00; </dt>
	<dd> the price to pay for the item</dd>
	<dt>tax: 0; </dt>
	<dd> the tax for the item</dd>
	<dt>locale: en; </dt>
	<dd> the language of the PayPal payment screen. Default is „en“.</dd>
	<dt>currency-code: USD; </dt>
	<dd> the currency for the payment. Default is USD.</dd>
	<dt>item-number: 1; </dt>
	<dd> the product item number </dd>
	<dt>cancel-url: http://domain.com/cancelled.html </dt>
	<dd> the url to redirect when cancelling the payment</dd>
	<dt>use-ipn: true; </dt>
	<dd> if set to true, paypal's instant payment notifications will be used to verify the payment. Default is false. If you would like to use IPN, please enable it as well in your paypal account. As IPN url please use your domain. You might like to know that</dd>
</dl>
<h3>PayPal实例</h3>
<pre class="prettyprint linenums">
{CBVerify 
plugin: paypal; 
require-view: en___30|de___31; 
verify-view: en___36|de___37; 
verify-levels: view, new, edit; 
verification-name: en___10 Day Subscription|de___10 Tage Mitgliedschaft; 
desc: en___Click here to pay!|de___Hier klicken zum Bezahlen!;
amount: en___19.00|de___15.00;
locale: en___en|de___de;
currency-code: en___USD|de___EUR;
}
</pre>
</body>
</html>
